<?php

use Hyperf\Database\Schema\Schema;
use Hyperf\Database\Schema\Blueprint;
use Hyperf\Database\Migrations\Migration;

class CreateSettingAppHiddenTable extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::create('setting_app_hidden', function (Blueprint $table) {
            $table->smallIncrements('id');
            $table->unsignedInteger('func_type')->default(0)->comment('功能类型');
            $table->string('app_id', 10)->default('')->comment('包ID（多选）');
            $table->string('version', 10)->default('')->comment('版本号（单选）');
            $table->string('channel', 200)->default('')->comment('渠道号（多选）');
            $table->unsignedTinyInteger('flag')->default(1)->comment('1有效，0无效');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('setting_app_hidden');
    }
}
